﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Site/QuanLyDuoc/QuanLyDuoc_OffCanvas.Master" AutoEventWireup="true" CodeBehind="ThanhToanHoaDon2.aspx.cs" Inherits="HospitalManager.QuanLyDuoc.HeThongTaiChinh.ThanhToanHoaDon2" %>

<%@ Register Src="HeThongTaiChinh_LeftMenu.ascx" TagName="HeThongTaiChinh_LeftMenu" TagPrefix="uc1" %>
<%@ Register Src="~/QuanLyDuoc/HeThongNhapXuat/PhieuNhapVatTu/uc_ViewPhieu.ascx" TagName="uc_ViewPhieu" TagPrefix="uc2" %>
<%@ Register Src="~/QuanLyDuoc/HeThongNhapXuat/PhieuTraNhaCungCap/uc_ViewPhieu.ascx" TagName="uc_ViewPhieu" TagPrefix="uc3" %>
<%@ Register Src="~/QuanLyDuoc/HeThongNhapXuat/PhieuHuy/uc_ViewPhieu.ascx" TagPrefix="uc4" TagName="uc_Viewphieu" %>
<%@ Register Src="../HeThongNhapXuat/PhieuXuatBanLe/uc_ViewPhieu.ascx" TagName="uc_ViewPhieu" TagPrefix="uc5" %>
<%@ Register Src="../HeThongNhapXuat/PhieuXuatKhac/uc_ViewPhieu.ascx" TagName="uc_ViewPhieu" TagPrefix="uc6" %>
<%@ Register Src="../HeThongNhapXuat/PhieuYeuCauXuatVatTu/uc_ViewPhieu.ascx" TagName="uc_ViewPhieu" TagPrefix="uc7" %>
<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="server">
    <script src="../../AjaxJquery/QuanLyDuoc/HeThongTaiChinh/jsThanhToanHoaDon.js"></script>
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="LeftContent" runat="server">
    <uc1:HeThongTaiChinh_LeftMenu ID="HeThongTaiChinh_LeftMenu1" runat="server" />
</asp:Content>
<asp:Content ID="Content3" ContentPlaceHolderID="MainContent" runat="server">
    <div class="row">
        <div class="col-xs-12 col-md-12">
            <div class="col-xs-12 col-md-12">
                <div class="page-header" style="margin: 0 0 10px;">
                    <h1 style="margin: 0; font-weight: bold; color: #3070A7; font-size: 30px;">THANH TOÁN HÓA ĐƠN
                    <small class="breadcrumb" style="font-size: 50%; background-color: #ffffff; padding: 0 15px;">
                        <li><a href="/QuanLyDuoc/HeThongTaiChinh/HeThongTaiChinh.aspx">HỆ THỐNG TÀI CHÍNH</a></li>
                        <li class="active">THANH TOÁN HÓA ĐƠN</li>
                    </small>
                    </h1>
                </div>
            </div>
        </div>
    </div>
    <div class="col-xs-3 col-md-3">
        <div class="list-group">
            <a id="li_phieunhapvattu" class="list-group-item" href="/QuanLyDuoc/HeThongTaiChinh/ThanhToanHoaDon.aspx?loaiphieu=li_phieunhapvattu">Phiếu nhập vật tư</a>
            <a id="li_phieukhachhangtralai" class="list-group-item" href="/QuanLyDuoc/HeThongTaiChinh/ThanhToanHoaDon.aspx?loaiphieu=li_phieukhachhangtralai">Phiếu khách hàng trả lại</a>
            <a id="li_phieuyeucauxuatvattu" class="list-group-item" href="/QuanLyDuoc/HeThongTaiChinh/ThanhToanHoaDon.aspx?loaiphieu=li_phieuyeucauxuatvattu">Phiếu yêu cầu xuất vật tư</a>
            <a id="li_phieuxuatkhosangkho" class="list-group-item" href="/QuanLyDuoc/HeThongTaiChinh/ThanhToanHoaDon.aspx?loaiphieu=li_phieuxuatkhosangkho">Phiếu xuất từ kho sang kho</a>
            <a id="li_phieunhaptukhokhac" class="list-group-item" href="/QuanLyDuoc/HeThongTaiChinh/ThanhToanHoaDon.aspx?loaiphieu=li_phieunhaptukhokhac">Phiếu nhập từ kho khác</a>
            <a id="li_phieutranhacungcap" class="list-group-item" href="/QuanLyDuoc/HeThongTaiChinh/ThanhToanHoaDon.aspx?loaiphieu=li_phieutranhacungcap">Phiếu trả nhà cung cấp</a>
            <a id="li_phieuxuatbanle" class="list-group-item" href="/QuanLyDuoc/HeThongTaiChinh/ThanhToanHoaDon.aspx?loaiphieu=li_phieuxuatbanle">Phiếu xuất bán lẻ</a>
            <a id="li_phieuxuatkhac" class="list-group-item" href="/QuanLyDuoc/HeThongTaiChinh/ThanhToanHoaDon.aspx?loaiphieu=li_phieuxuatkhac">Phiếu xuất khác</a>
            <a id="li_phieuxuathuy" class="list-group-item" href="/QuanLyDuoc/HeThongTaiChinh/ThanhToanHoaDon.aspx?loaiphieu=li_phieuxuathuy">Phiếu xuất hủy</a>
        </div>
    </div>
    <div class="col-xs-9 col-md-9">
        <div class="row">
            <div class="form-horizontal">
                    <div class="col-xs-4 col-md-4">
                        <asp:DropDownList ID="ddlKho_Khoa" runat="server" ClientIDMode="Static">
                        </asp:DropDownList>
                    </div>
                    <div class="col-xs-6 col-md-6">
                        <div class="input-group">
                            <span class="input-group-addon">Từ ngày</span>
                            <asp:TextBox ID="txtTuNgay" ClientIDMode="Static" runat="server" CssClass="form-control ipdate dateFormat"
                                placeholder="Từ ngày"></asp:TextBox>
                            <span class="input-group-addon" style="border-right: 0;">đến ngày</span>
                            <asp:TextBox ID="txtDenNgay" ClientIDMode="Static" runat="server" CssClass="form-control ipdate dateFormat"
                                placeholder="Đến ngày"></asp:TextBox>
                        </div>
                    </div>
                    <div class="col-xs-2 col-md-2">
                        <asp:Button ID="btnTimKiem" ClientIDMode="Static" runat="server" Text="Tìm kiếm" CssClass="btn btn-default"
                            OnClientClick="validationform_Timkiem()" OnClick="btnTimKiem_Click" />
                    </div>
            </div>
        </div>
        <div class="row" style="margin-top: 10px;">
            <div class="col-md-12">
                <div class="form-group table-responsive">
                    <%--Phiếu nhập vật tư--%>
                    <asp:GridView ID="gvPhieuNhapVatTu" runat="server" AutoGenerateColumns="False" Width="100%" OnRowDataBound="gvPhieuNhapVatTu_RowDataBound"
                        CssClass="table table-bordered table-condensed" DataKeyNames="MaPhieuNhap" Visible="False">
                        <Columns>
                            <asp:BoundField DataField="RowNumber" HeaderText="STT">
                                <ItemStyle HorizontalAlign="Center"></ItemStyle>
                            </asp:BoundField>
                            <asp:BoundField DataField="NgayGiao" HeaderText="Ngày giao" DataFormatString="{0:dd-MM-yyyy}">
                                <ItemStyle HorizontalAlign="Center"></ItemStyle>
                            </asp:BoundField>
                            <asp:BoundField DataField="TenKho" HeaderText="Kho nhập"></asp:BoundField>
                            <asp:BoundField DataField="NguoiGiao" HeaderText="Người giao"></asp:BoundField>
                            <asp:BoundField DataField="NguoiNhan" HeaderText="Người nhận"></asp:BoundField>
                            <asp:BoundField DataField="TongTien" HeaderText="Tổng tiền" DataFormatString="{0:n0}">
                                <ItemStyle HorizontalAlign="Right"></ItemStyle>
                            </asp:BoundField>
                            <asp:BoundField DataField="Thue" HeaderText="Thuế">
                                <ItemStyle HorizontalAlign="Right"></ItemStyle>
                            </asp:BoundField>
                            <asp:TemplateField>
                                <ItemTemplate>
                                    <asp:LinkButton ID="btnViewPhieuNhapVatTu" ClientIDMode="Static" runat="server" ToolTip="Xem thông tin phiếu"
                                        CssClass="btn btn-success" maphieunhap='<%# Eval("MaPhieuNhap") %>' OnClientClick="viewphieunhapvattu(this);" href="javascript:void(0)">
                                    <i class="glyphicon glyphicon-search"></i>
                                    </asp:LinkButton>
                                    <asp:LinkButton ID="btnDuyetPhieuNhapVatTu" ClientIDMode="Static" runat="server" ToolTip="Duyệt phiếu"
                                        CssClass="btn btn-info" CommandArgument='<%# Eval("MaPhieuNhap") %>' OnClick="btnDuyetPhieuNhapVatTu_Click">
                                    <i class="glyphicon glyphicon-check"></i>
                                    </asp:LinkButton>
                                    <asp:LinkButton ID="btnTraLaiPhieuNhapVatTu" ClientIDMode="Static" runat="server" ToolTip="Trả lại phiếu"
                                        CssClass="btn btn-danger" CommandArgument='<%# Eval("MaPhieuNhap") %>' OnClick="btnTraLaiPhieuNhapVatTu_Click">
                                    <i class="glyphicon glyphicon-share"></i>
                                    </asp:LinkButton>
                                </ItemTemplate>
                                <ItemStyle HorizontalAlign="Center" />
                            </asp:TemplateField>
                        </Columns>
                    </asp:GridView>
                    <%--Phiếu trả nhà cung cấp--%>
                    <asp:GridView ID="gvPhieuTraNhaCungCap" runat="server" AutoGenerateColumns="False" Width="100%"
                        CssClass="table table-bordered table-condensed" DataKeyNames="MaPhieu" Visible="False" OnRowCreated="gvPhieuTraNhaCungCap_RowCreated">
                        <Columns>
                            <asp:BoundField DataField="RowNumber" HeaderText="STT">
                                <ItemStyle HorizontalAlign="Center"></ItemStyle>
                            </asp:BoundField>
                            <asp:BoundField DataField="NgayTra" HeaderText="Ngày trả" DataFormatString="{0:dd-MM-yyyy}">
                                <ItemStyle HorizontalAlign="Center"></ItemStyle>
                            </asp:BoundField>
                            <asp:BoundField DataField="TenKho" HeaderText="Tên kho"></asp:BoundField>
                            <asp:BoundField DataField="TenNhaCungCap" HeaderText="Nhà Cung Cấp"></asp:BoundField>
                            <asp:BoundField DataField="NguoiTra" HeaderText="Người trả"></asp:BoundField>
                            <asp:BoundField DataField="NguoiNhan" HeaderText="Người nhận"></asp:BoundField>
                            <asp:BoundField DataField="TongThuoc" HeaderText="Tổng thuốc" DataFormatString="{0:n0}">
                                <ItemStyle HorizontalAlign="Right"></ItemStyle>
                            </asp:BoundField>
                            <asp:BoundField DataField="TongTien" HeaderText="Tổng tiền" DataFormatString="{0:n0}">
                                <ItemStyle HorizontalAlign="Right"></ItemStyle>
                            </asp:BoundField>
                            <asp:BoundField DataField="Thue" HeaderText="Thuế">
                                <ItemStyle HorizontalAlign="Right"></ItemStyle>
                            </asp:BoundField>
                            <asp:BoundField DataField="TongTienSauThue" HeaderText="Tổng tiền sau thuế" DataFormatString="{0:n0}">
                                <ItemStyle HorizontalAlign="Right"></ItemStyle>
                            </asp:BoundField>
                            <asp:TemplateField>
                                <ItemTemplate>
                                    <asp:LinkButton ID="btnViewPhieu" ClientIDMode="Static" runat="server" ToolTip="Xem thông tin phiếu"
                                        CssClass="btn btn-success" maphieu='<%# Eval("MaPhieu") %>' OnClientClick="viewphieutranhacungcap(this);" href="javascript:void(0)">
                                    <i class="glyphicon glyphicon-search"></i>
                                    </asp:LinkButton>
                                    <asp:LinkButton ID="btnDuyetPhieu" ClientIDMode="Static" runat="server" ToolTip="Duyệt phiếu"
                                        CssClass="btn btn-info" CommandArgument='<%# Eval("MaPhieu") %>' OnClick="btnDuyetPhieu_Click">
                                    <i class="glyphicon glyphicon-check"></i>
                                    </asp:LinkButton>
                                    <asp:LinkButton ID="btnXoaPhieu" ClientIDMode="Static" runat="server" ToolTip="Xóa phiếu"
                                        CssClass="btn btn-danger" CommandArgument='<%# Eval("MaPhieu") %>'
                                        OnClientClick="return showconfirm(this.id);" OnClick="btnXoaPhieu_Click">
                                    <i class="glyphicon glyphicon-trash"></i>
                                    </asp:LinkButton>
                                </ItemTemplate>
                                <ItemStyle HorizontalAlign="Center" Width="15%" />
                            </asp:TemplateField>
                        </Columns>
                    </asp:GridView>
                    <%--Phiếu hủy--%>
                    <asp:GridView ID="gvPhieuHuy" runat="server" AutoGenerateColumns="False" Width="100%"
                        CssClass="table table-bordered table-condensed" DataKeyNames="MaPhieu" Visible="False" OnRowCreated="gvPhieuHuy_RowCreated">
                        <Columns>
                            <asp:BoundField DataField="RowNumber" HeaderText="STT">
                                <ItemStyle HorizontalAlign="Center"></ItemStyle>
                            </asp:BoundField>
                            <asp:BoundField DataField="NgayHuy" HeaderText="Ngày hủy" DataFormatString="{0:dd-MM-yyyy}">
                                <ItemStyle HorizontalAlign="Center"></ItemStyle>
                            </asp:BoundField>
                            <asp:BoundField DataField="TenKho" HeaderText="Kho"></asp:BoundField>
                            <asp:BoundField DataField="NguoiHuy" HeaderText="Người hủy"></asp:BoundField>
                            <asp:BoundField DataField="NguoiGiamSat" HeaderText="Người giám sát"></asp:BoundField>
                            <asp:BoundField DataField="TongThuoc" HeaderText="Tổng thuốc" DataFormatString="{0:n0}">
                                <ItemStyle HorizontalAlign="Right"></ItemStyle>
                            </asp:BoundField>
                            <asp:BoundField DataField="TongTien" HeaderText="Tổng tiền" DataFormatString="{0:n0}">
                                <ItemStyle HorizontalAlign="Right"></ItemStyle>
                            </asp:BoundField>
                            <asp:TemplateField>
                                <ItemTemplate>
                                    <asp:LinkButton ID="btnViewPhieuHuy" ClientIDMode="Static" runat="server" ToolTip="Xem thông tin phiếu"
                                        CssClass="btn btn-success" maphieu='<%# Eval("MaPhieu") %>' OnClientClick="viewphieuhuy(this);" href="javascript:void(0)">
                                    <i class="glyphicon glyphicon-search"></i>
                                    </asp:LinkButton>
                                    <asp:LinkButton ID="btnDuyetPhieuHuy" ClientIDMode="Static" runat="server" ToolTip="Duyệt phiếu"
                                        CssClass="btn btn-info" CommandArgument='<%# Eval("MaPhieu") %>' OnClick="btnDuyetPhieuHuy_Click">
                                    <i class="glyphicon glyphicon-check"></i>
                                    </asp:LinkButton>
                                    <asp:LinkButton ID="btnXoaPhieuHuy" ClientIDMode="Static" runat="server" ToolTip="Xóa phiếu"
                                        CssClass="btn btn-danger" CommandArgument='<%# Eval("MaPhieu") %>'
                                        OnClientClick="return showconfirm(this.id);" OnClick="btnXoaPhieuHuy_Click">
                                    <i class="glyphicon glyphicon-trash"></i>
                                    </asp:LinkButton>
                                </ItemTemplate>
                                <ItemStyle HorizontalAlign="Center" Width="15%" />
                            </asp:TemplateField>
                        </Columns>
                    </asp:GridView>
                    <%--Phiếu xuất bán lẻ--%>
                    <asp:GridView ID="gvPhieuXuatBanLe" runat="server" AutoGenerateColumns="False" Width="100%"
                        CssClass="table table-bordered table-condensed" DataKeyNames="MaPhieu" Visible="False" OnRowCreated="gvPhieuXuatBanLe_RowCreated">
                        <Columns>
                            <asp:BoundField DataField="RowNumber" HeaderText="STT">
                                <ItemStyle HorizontalAlign="Center"></ItemStyle>
                            </asp:BoundField>
                            <asp:BoundField DataField="NgayGiao" HeaderText="Ngày giao" DataFormatString="{0:dd-MM-yyyy}">
                                <ItemStyle HorizontalAlign="Center"></ItemStyle>
                            </asp:BoundField>
                            <asp:BoundField DataField="TenKho" HeaderText="Tên kho"></asp:BoundField>
                            <asp:BoundField DataField="TenKhachHang" HeaderText="Tên khách hàng"></asp:BoundField>
                            <asp:BoundField DataField="NguoiGiao" HeaderText="Người giao"></asp:BoundField>
                            <asp:BoundField DataField="TongThuoc" HeaderText="Tổng thuốc" DataFormatString="{0:n0}">
                                <ItemStyle HorizontalAlign="Right"></ItemStyle>
                            </asp:BoundField>
                            <asp:BoundField DataField="TongTien" HeaderText="Tổng tiền" DataFormatString="{0:n0}">
                                <ItemStyle HorizontalAlign="Right"></ItemStyle>
                            </asp:BoundField>
                            <asp:TemplateField>
                                <ItemTemplate>
                                    <asp:LinkButton ID="btnViewPhieuXuatBanLe" ClientIDMode="Static" runat="server" ToolTip="Xem thông tin phiếu"
                                        CssClass="btn btn-success" maphieu='<%# Eval("MaPhieu") %>' OnClientClick="viewphieuxuatbanle(this);" href="javascript:void(0)">
                                    <i class="glyphicon glyphicon-search"></i>
                                    </asp:LinkButton>
                                    <asp:LinkButton ID="btnDuyetPhieuXuatBanLe" ClientIDMode="Static" runat="server" ToolTip="Duyệt phiếu"
                                        CssClass="btn btn-info" CommandArgument='<%# Eval("MaPhieu") %>' OnClick="btnDuyetPhieuXuatBanLe_Click">
                                    <i class="glyphicon glyphicon-check"></i>
                                    </asp:LinkButton>
                                    <asp:LinkButton ID="btnXoaPhieuXuatBanLe" ClientIDMode="Static" runat="server" ToolTip="Xóa phiếu"
                                        CssClass="btn btn-danger" CommandArgument='<%# Eval("MaPhieu") %>'
                                        OnClientClick="return showconfirm(this.id);" OnClick="btnXoaPhieuXuatBanLe_Click">
                                    <i class="glyphicon glyphicon-trash"></i>
                                    </asp:LinkButton>
                                </ItemTemplate>
                                <ItemStyle HorizontalAlign="Center" Width="15%" />
                            </asp:TemplateField>
                        </Columns>
                    </asp:GridView>
                    <%--Phiếu xuất khác--%>
                    <asp:GridView ID="gvPhieuXuatKhac" runat="server" AutoGenerateColumns="False" Width="100%"
                        CssClass="table table-bordered table-condensed" DataKeyNames="MaPhieu" Visible="False" OnRowCreated="gvPhieuXuatKhac_RowCreated">
                        <Columns>
                            <asp:BoundField DataField="RowNumber" HeaderText="STT">
                                <ItemStyle HorizontalAlign="Center"></ItemStyle>
                            </asp:BoundField>
                            <asp:BoundField DataField="NgayGiao" HeaderText="Ngày giao" DataFormatString="{0:dd-MM-yyyy}">
                                <ItemStyle HorizontalAlign="Center"></ItemStyle>
                            </asp:BoundField>
                            <asp:BoundField DataField="TenKho" HeaderText="Kho"></asp:BoundField>
                            <asp:BoundField DataField="NguoiGiao" HeaderText="Người xuất khác"></asp:BoundField>
                            <asp:BoundField DataField="NguoiNhan" HeaderText="Người giám sát"></asp:BoundField>
                            <asp:BoundField DataField="TongThuoc" HeaderText="Tổng thuốc" DataFormatString="{0:n0}">
                                <ItemStyle HorizontalAlign="Right"></ItemStyle>
                            </asp:BoundField>
                            <asp:BoundField DataField="TongTien" HeaderText="Tổng tiền" DataFormatString="{0:n0}">
                                <ItemStyle HorizontalAlign="Right"></ItemStyle>
                            </asp:BoundField>
                            <asp:TemplateField>
                                <ItemTemplate>
                                    <asp:LinkButton ID="btnViewPhieuXuatKhac" ClientIDMode="Static" runat="server" ToolTip="Xem thông tin phiếu"
                                        CssClass="btn btn-success" maphieu='<%# Eval("MaPhieu") %>' OnClientClick="viewphieuxuatkhac(this);" href="javascript:void(0)">
                                    <i class="glyphicon glyphicon-search"></i>
                                    </asp:LinkButton>
                                    <asp:LinkButton ID="btnDuyetPhieuXuatKhac" ClientIDMode="Static" runat="server" ToolTip="Duyệt phiếu"
                                        CssClass="btn btn-info" CommandArgument='<%# Eval("MaPhieu") %>' OnClick="btnDuyetPhieuXuatKhac_Click">
                                    <i class="glyphicon glyphicon-check"></i>
                                    </asp:LinkButton>
                                    <asp:LinkButton ID="btnXoaPhieuXuatKhac" ClientIDMode="Static" runat="server" ToolTip="Xóa phiếu"
                                        CssClass="btn btn-danger" CommandArgument='<%# Eval("MaPhieu") %>'
                                        OnClientClick="return showconfirm(this.id);" OnClick="btnXoaPhieuXuatKhac_Click">
                                    <i class="glyphicon glyphicon-trash"></i>
                                    </asp:LinkButton>
                                </ItemTemplate>
                                <ItemStyle HorizontalAlign="Center" Width="15%" />
                            </asp:TemplateField>
                        </Columns>
                    </asp:GridView>
                    <%--Phiếu yêu cầu xuất vật tư--%>
                    <asp:GridView ID="gvPhieuYeuCauXuatVatTu" runat="server" AutoGenerateColumns="False" Width="100%"
                        CssClass="table table-bordered table-condensed" DataKeyNames="MaPhieu" Visible="False" OnRowCreated="gvPhieuYeuCauXuatVatTu_RowCreated">
                        <Columns>
                            <asp:BoundField DataField="RowNumber" HeaderText="STT">
                                <ItemStyle HorizontalAlign="Center"></ItemStyle>
                            </asp:BoundField>
                            <asp:BoundField DataField="NgayYeuCau" HeaderText="Ngày yêu cầu" DataFormatString="{0:dd-MM-yyyy}">
                                <ItemStyle HorizontalAlign="Center"></ItemStyle>
                            </asp:BoundField>
                            <asp:BoundField DataField="NguoiYeuCau" HeaderText="Người yêu cầu"></asp:BoundField>
                            <asp:BoundField DataField="TenKhoYeuCau" HeaderText="Kho yêu cầu"></asp:BoundField>
                            <asp:BoundField DataField="TenKhoXuat" HeaderText="Kho xuất"></asp:BoundField>
                            <asp:BoundField DataField="TongThuoc" HeaderText="Tổng thuốc" DataFormatString="{0:n0}">
                                <ItemStyle HorizontalAlign="Right"></ItemStyle>
                            </asp:BoundField>
                            <asp:TemplateField>
                                <ItemTemplate>
                                    <asp:LinkButton ID="btnViewPhieuYeuCauXuatVatTu" ClientIDMode="Static" runat="server" ToolTip="Xem thông tin phiếu"
                                        CssClass="btn btn-success" maphieu='<%# Eval("MaPhieu") %>' OnClientClick="viewphieuyeucauxuatvattu(this);" href="javascript:void(0)">
                                    <i class="glyphicon glyphicon-search"></i>
                                    </asp:LinkButton>
                                    <asp:LinkButton ID="btnDuyetPhieuYeuCauXuatVatTu" ClientIDMode="Static" runat="server" ToolTip="Duyệt phiếu"
                                        CssClass="btn btn-info" CommandArgument='<%# Eval("MaPhieu") %>' OnClick="btnDuyetPhieuYeuCauXuatVatTu_Click">
                                    <i class="glyphicon glyphicon-check"></i>
                                    </asp:LinkButton>
                                    <asp:LinkButton ID="btnXoaPhieuYeuCauXuatVatTu" ClientIDMode="Static" runat="server" ToolTip="Xóa phiếu"
                                        CssClass="btn btn-danger" CommandArgument='<%# Eval("MaPhieu") %>'
                                        OnClientClick="return showconfirm(this.id);" OnClick="btnXoaPhieuYeuCauXuatVatTu_Click">
                                    <i class="glyphicon glyphicon-trash"></i>
                                    </asp:LinkButton>
                                </ItemTemplate>
                                <ItemStyle HorizontalAlign="Center" Width="15%" />
                            </asp:TemplateField>
                        </Columns>
                    </asp:GridView>
                </div>
            </div>
        </div>
        <div class="row">
            <div class="col-md-6">
            </div>
            <div class="col-md-6" style="text-align: right;">
                <asp:DataList RepeatDirection="Horizontal" runat="server" ID="dlPager" OnItemCommand="dlPager_ItemCommand"
                    CssClass="tbPage">
                    <ItemTemplate>
                        <asp:LinkButton Enabled='<%#Eval("Enabled") %>' runat="server" ID="lnkPageNo" Text='<%#Eval("Text") %>'
                            CommandArgument='<%#Eval("Value") %>' CommandName="PageNo"></asp:LinkButton>
                    </ItemTemplate>
                </asp:DataList>
            </div>
        </div>
    </div>
    <asp:HiddenField ID="hfPageIndex" runat="server" Value="1" />
    <script type="text/javascript">
        $(function () {
            $(function () {
                $("#li_thanhtoanhoadon").addClass("active");
                $("#li_hethongtaichinh").addClass("active");
            });
        });
    </script>
</asp:Content>
<asp:Content ID="Content4" ContentPlaceHolderID="FormContent" runat="server">
    <!-- Modal view thông tin phiếu nhập vật tư -->
    <div id="div_phieunhapvattu_view" class="modal fade" tabindex="-1" role="dialog" data-backdrop="static"
        data-width="98%" aria-hidden="true">
        <div class="modal-dialog">
            <div class="modal-content">
                <div class="modal-header">
                    <button type="button" class="close" data-dismiss="modal" style="line-height: 1;">
                        <span>&times;</span><span class="sr-only">Close</span></button>
                    <h4 class="modal-title">Phiếu nhập vật tư</h4>
                </div>
                <div class="modal-body modal-fullheight">
                    <uc2:uc_ViewPhieu ID="uc_ViewPhieu1" runat="server" />
                </div>
            </div>
        </div>
    </div>
    <!-- Modal view thông tin phiếu trả nhà cung cấp -->
    <div id="div_phieutranhacungcap_view" class="modal fade" tabindex="-1" role="dialog" data-backdrop="static"
        data-width="98%" aria-hidden="true">
        <div class="modal-dialog">
            <div class="modal-content">
                <div class="modal-header">
                    <button type="button" class="close" data-dismiss="modal" style="line-height: 1;">
                        <span>&times;</span><span class="sr-only">Close</span></button>
                    <h4 class="modal-title">Phiếu trả nhà cung cấp</h4>
                </div>
                <div class="modal-body modal-fullheight">
                    <uc3:uc_ViewPhieu ID="uc_ViewPhieu2" runat="server" />
                </div>
            </div>
        </div>
    </div>
    <!-- Modal view thông tin phiếu hủy -->
    <div id="div_phieuhuy_view" class="modal fade" tabindex="-1" role="dialog" data-backdrop="static"
        data-width="98%" aria-hidden="true">
        <div class="modal-dialog">
            <div class="modal-content">
                <div class="modal-header">
                    <button type="button" class="close" data-dismiss="modal" style="line-height: 1;">
                        <span>&times;</span><span class="sr-only">Close</span></button>
                    <h4 class="modal-title">Phiếu hủy</h4>
                </div>
                <div class="modal-body modal-fullheight">
                    <uc4:uc_Viewphieu ID="uc_ViewPhieu3" runat="server" />
                </div>
            </div>
        </div>
    </div>
    <!-- Modal view thông tin phiếu xuất bán lẻ -->
    <div id="div_phieuxuatbanle_view" class="modal fade" tabindex="-1" role="dialog" data-backdrop="static"
        data-width="98%" aria-hidden="true">
        <div class="modal-dialog">
            <div class="modal-content">
                <div class="modal-header">
                    <button type="button" class="close" data-dismiss="modal" style="line-height: 1;">
                        <span>&times;</span><span class="sr-only">Close</span></button>
                    <h4 class="modal-title">Phiếu xuất bán lẻ</h4>
                </div>
                <div class="modal-body modal-fullheight">
                    <uc5:uc_ViewPhieu ID="uc_ViewPhieu4" runat="server" />
                </div>
            </div>
        </div>
    </div>
    <!-- Modal view thông tin phiếu xuất khác -->
    <div id="div_phieuxuatkhac_view" class="modal fade" tabindex="-1" role="dialog" data-backdrop="static"
        data-width="98%" aria-hidden="true">
        <div class="modal-dialog">
            <div class="modal-content">
                <div class="modal-header">
                    <button type="button" class="close" data-dismiss="modal" style="line-height: 1;">
                        <span>&times;</span><span class="sr-only">Close</span></button>
                    <h4 class="modal-title" id="myModalLabel_view">Phiếu xuất khác</h4>
                </div>
                <div class="modal-body modal-fullheight">
                    <uc6:uc_ViewPhieu ID="uc_ViewPhieu5" runat="server" />
                </div>
            </div>
        </div>
    </div>
    <!-- Modal view thông tin phiếu yêu cầu xuất vật tư -->
    <div id="div_phieuyeucauxuatvattu_view" class="modal fade" tabindex="-1" role="dialog" data-backdrop="static"
        data-width="98%" aria-hidden="true">
        <div class="modal-dialog">
            <div class="modal-content">
                <div class="modal-header">
                    <button type="button" class="close" data-dismiss="modal" style="line-height: 1;">
                        <span>&times;</span><span class="sr-only">Close</span></button>
                    <h4 class="modal-title" id="H1">Phiếu yêu cầu xuất vật tư</h4>
                </div>
                <div class="modal-body modal-fullheight">
                    <uc7:uc_ViewPhieu ID="uc_ViewPhieu6" runat="server" />
                </div>
            </div>
        </div>
    </div>
</asp:Content>
